<?php
return array(
	'attributeLabels'=>array(
		'departure_time' => '出发时间',
		'return_time' => '返回时间',
		'total_num' => '总人数',
		'num' => '成团人数',
		'day_number'=>'出行天数',
	),

	'rules'=>array(
		array('company_id','required'),
		array('total_num,emergency_tel,travel_province,travel_city,departure_time,return_time,departure_province,departure_city,departure_address','required'),
        array('type,num,day_number,start_time,end_time','required'),
        array('num,total_num','numerical','max'=>99,'min'=>1),
        array('day_number','numerical','max'=>99),
        PregRules::phoneRules('emergency_tel'),
	),

	'relations' => array(
		'company' => array(CActiveRecord::BELONGS_TO, 'TravelAgency','company_id'),
	    'goods' => array(CActiveRecord::BELONGS_TO,'Travel','goods_id'),
	),
	
	'behaviors' => array(
		'fornt' => array(
			'class' => 'coms.behaviors.FrontBehavior',
			'attributes' => array(
				'desc' => 'desc',
			),
		),
	),

	'_import' => array(
		array('*', 'models.ActiveRecord//*'),
	),
);